wayland: Unset window_impl->commit_pending when hiding the surface
authorCarlos Garnacho <carlosg@gnome.org>
Mon, 1 Sep 2014 18:20:49 +0000 (20:20 +0200)
committerCarlos Garnacho <carlosg@gnome.org>
Mon, 1 Sep 2014 20:44:08 +0000 (22:44 +0200)
A surface may be hidden when a frame is already scheduled, which may cause
crashes on on_frame_clock_after_paint() when calling commit() on a NULL
surface. To fix this, ensure commit_pending is also set to FALSE when the
surface is gone.

https://bugzilla.gnome.org/show_bug.cgi?id=735226

gdk/wayland/gdkwindow-wayland.c

index d40599e696c2460d6c77d6a135e29e7fce64644e..2dcc552257b0c69e2e343373b08410725cab4f13 100644 (file)
@@ -1182,6 +1182,7 @@ gdk_wayland_window_hide_surface (GdkWindow *window)
       impl->outputs = NULL;
     }
 
+  impl->pending_commit = FALSE;
   impl->mapped = FALSE;
 }